# 九九乘法表
for i in range(1, 10):
    for j in range(1, i+1):
        mun = i * j
        print(f'{j}*{i}={mun}', end='\t')
    print()

print('-----------------------------------------------------------------------------------')

for i in range(9, 0, -1):
    for j in range(i, 0, -1):
        mun = i * j
        print(f'{j}*{i}={mun}', end='\t')
    print()

# ===========================================================================================

# 冒泡排序
a = [1, 6, 2, 9, 0]
times = len(a) - 1
while times > 0:
    for y in range(times):
        if a[y] > a[y+1]:
            a[y], a[y+1] = a[y+1], a[y]
    times -= 1
print(a)

# ============================================================================================

# 1-100的和
ret = 0
for i in range(1, 101):
    ret += i
print(ret)